//
//  UIScrollView+OAExtension.m
//  OARetail
//
//  Created by ChenJie on 5/17/20.
//  Copyright © 2020 Mist. All rights reserved.
//

#import "UIScrollView+OAExtension.h"

@implementation UIScrollView (OAExtension)

//
- (CGFloat)oa_contentOffsetY {
    return self.contentOffset.y;
}

- (void)oa_setContentOffsetY:(CGFloat)oa_contentOffsetY {
    CGPoint contentOffset = self.contentOffset;
    contentOffset.y = oa_contentOffsetY;
    self.contentOffset = contentOffset;
}

//
- (CGFloat)oa_contentInsetTop {
    return self.contentInset.top;
}

- (void)oa_setContentInsetTop:(CGFloat)oa_contentInsetTop {
    UIEdgeInsets contentInset = self.contentInset;
    contentInset.top = oa_contentInsetTop;
    self.contentInset = contentInset;
}

@end
